package com.kingdom.admin.view;

import com.alibaba.fastjson.JSON;
import com.kingdom.admin.entity.SystemUser;
import com.kingdom.admin.service.SystemUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Configurable;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by xinchunting on 17-12-4.
 */
@Controller
@EnableAutoConfiguration
@Configurable
public class test {
    @Autowired
    private SystemUserService systemUserService;


    @RequestMapping(value ="/api", method = RequestMethod.GET)
    @ResponseBody
    public String list(SystemUser systemUser) {
        SystemUser systemUsers = systemUserService.insert(systemUser);
        return JSON.toJSONString("1111");
    }
}
